package com.lpwa.system.domain;


import com.fasterxml.jackson.annotation.JsonFormat;
import com.lpwa.common.annotation.Excel;
import com.lpwa.common.core.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.math.BigDecimal;
import java.util.Date;

/**
 * 标签表 sys_tag
 * 
 * @author tanmu
 * @date 2019-06-03
 */
public class Tag extends BaseEntity
{
	private static final long serialVersionUID = 1L;
	/** ID */
	private Integer id;
	/** 标签ID */
	@Excel(name = "标签ID")
	private String tagId;
	/** 标签类型 */
	private String tagType;
	/** 型号 */
	@Excel(name = "型号")
	private String modelNumber;
	/** 型号类型 */
	@Excel(name = "类型")
	private String modelType;
	/** 在线情况（0离线 1在线） */
	@Excel(name = "在线情况",readConverterExp = "0=离线,1=在线")
	private Integer isOnline;
	/** 位置信息时间 */
	private Date positionTS;
	/** 电量 */
	@Excel(name = "电量")
	private BigDecimal batteryVoltage;
	/** 电池电量对应的时间 */
	@Excel(name = "电池电量时间")
	private Date batteryVoltageTS;
	/** 是否低电（0否 1是） */
//	@Excel(name = "是否低电",readConverterExp = "0=正常,1=低电")
	private Integer isLow;

	/** 是否已删除（0未删除 1删除） */
	private Integer isDeleted;
    /** 是否绑定（0未绑定 1绑定） */
//	@Excel(name = "是否绑定",readConverterExp = "0=未绑定,1=绑定")
	private Integer isBind;
    /** 人员ID */
//	@Excel(name = "人员ID")
    private String personId;

    private String assetId;
	/** 数据产生时间 */
	private Date lastPacketTS;
	/** X */
	private BigDecimal x;
	/** Y */
	private BigDecimal y;
	/** Z */
	private BigDecimal z;

	/** 信号强度 */
	@Excel(name = "信号强度")
	private Integer rssi;
	/** 采集信号强度的对应基站ID */
	@Excel(name = "rssi基站ID")
	private String rssiLocator;
	/** 报警状态 */
	@Excel(name = "报警状态")
	private String status;
	/** 传感类型 */
	@Excel(name = "传感类型")
	private String sensorType;
	/** 传感值 */
//	@Excel(name = "传感值")
	private String sensorValue;
	/** 传感值 */
	@Excel(name = "传感值")
	private Integer sensorData;
	/** 更新时间 */
	@Excel(name = "更新时间", dateFormat="yyyy-MM-dd HH:mm:ss")
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private Date updateTime;
	private String locatorId;

	public String getLocatorId() {
		return locatorId;
	}

	public void setLocatorId(String locatorId) {
		this.locatorId = locatorId;
	}

	@Override
	public Date getUpdateTime() {
		return updateTime;
	}

	@Override
	public void setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
	}

	public Date getPositionTS() {
		return positionTS;
	}

	public void setPositionTS(Date positionTS) {
		this.positionTS = positionTS;
	}

	public Date getLastPacketTS() {
		return lastPacketTS;
	}

	public void setLastPacketTS(Date lastPacketTS) {
		this.lastPacketTS = lastPacketTS;
	}

	public BigDecimal getX() {
		return x;
	}

	public void setX(BigDecimal x) {
		this.x = x;
	}

	public BigDecimal getY() {
		return y;
	}

	public void setY(BigDecimal y) {
		this.y = y;
	}

	public BigDecimal getZ() {
		return z;
	}

	public void setZ(BigDecimal z) {
		this.z = z;
	}

	public Date getBatteryVoltageTS() {
		return batteryVoltageTS;
	}

	public void setBatteryVoltageTS(Date batteryVoltageTS) {
		this.batteryVoltageTS = batteryVoltageTS;
	}

	public Integer getRssi() {
		return rssi;
	}

	public void setRssi(Integer rssi) {
		this.rssi = rssi;
	}

	public String getRssiLocator() {
		return rssiLocator;
	}

	public void setRssiLocator(String rssiLocator) {
		this.rssiLocator = rssiLocator;
	}

	public String getStatus() {
		return status;
	}

	public void setStatus(String status) {
		this.status = status;
	}

	public String getSensorType() {
		return sensorType;
	}

	public void setSensorType(String sensorType) {
		this.sensorType = sensorType;
	}

	public Integer getSensorData() {
		return sensorData;
	}

	public void setSensorData(Integer sensorData) {
		this.sensorData = sensorData;
	}

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getTagId() {
		return tagId;
	}

	public void setTagId(String tagId) {
		this.tagId = tagId;
	}

	public String getTagType() {
		return tagType;
	}

	public void setTagType(String tagType) {
		this.tagType = tagType;
	}

	public BigDecimal getBatteryVoltage() {
		return batteryVoltage;
	}

	public void setBatteryVoltage(BigDecimal batteryVoltage) {
		this.batteryVoltage = batteryVoltage;
	}

	public Integer getIsLow() {
		return isLow;
	}

	public void setIsLow(Integer isLow) {
		this.isLow = isLow;
	}

	public Integer getIsOnline() {
		return isOnline;
	}

	public void setIsOnline(Integer isOnline) {
		this.isOnline = isOnline;
	}

	public String getSensorValue() {
		return sensorValue;
	}

	public void setSensorValue(String sensorValue) {
		this.sensorValue = sensorValue;
	}

	public Integer getIsDeleted() {
		return isDeleted;
	}

	public void setIsDeleted(Integer isDeleted) {
		this.isDeleted = isDeleted;
	}

	public String getModelNumber() {
		return modelNumber;
	}

	public void setModelNumber(String modelNumber) {
		this.modelNumber = modelNumber;
	}

	public String getModelType() {
		return modelType;
	}

	public void setModelType(String modelType) {
		this.modelType = modelType;
	}

	public Integer getIsBind() {
		return isBind;
	}

	public void setIsBind(Integer isBind) {
		this.isBind = isBind;
	}

	public String getPersonId() {
		return personId;
	}

	public void setPersonId(String personId) {
		this.personId = personId;
	}

	public String getAssetId() {
		return assetId;
	}

	public void setAssetId(String assetId) {
		this.assetId = assetId;
	}

	public String toString() {
		return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
				.append("id", getId())
				.append("tagId", getTagId())
				.append("tagType", getTagType())
				.append("isOnline", getIsOnline())
				.append("positionTS", getPositionTS())
				.append("lastPacketTS", getLastPacketTS())
				.append("x", getX())
				.append("y", getY())
				.append("z", getZ())
				.append("batteryVoltage", getBatteryVoltage())
				.append("batteryVoltageTS", getBatteryVoltageTS())
				.append("rssi", getRssi())
				.append("rssiLocator", getRssiLocator())
				.append("status", getStatus())
				.append("sensorType", getSensorType())
				.append("sensorData", getSensorData())
				.append("personId", getPersonId())
				.append("isDeleted", getIsDeleted())
				.append("createBy", getCreateBy())
				.append("createTime", getCreateTime())
				.append("updateBy", getUpdateBy())
				.append("updateTime", getUpdateTime())
				.append("remark", getRemark())
				.append("isBind", getIsBind())
				.toString();
	}
}
